﻿using SlimDX;
using SlimDX.DirectInput;


namespace InsTron
{
    static class GameControls
    {
        public static Key[] accelerateKey;
        public static Key[] brakeKey;
        public static Key[] leftKey;
        public static Key[] rightKey;
        public static Key pauseKey;

        public static void Initialize()
        {
            accelerateKey = new Key[2];
            brakeKey = new Key[2];
            leftKey = new Key[2];
            rightKey = new Key[2];

            InitializePlayer1();
            InitializePlayer2();
            pauseKey = Key.P;
        }


        private static void InitializePlayer1()
        {
            accelerateKey[0] = Key.W;
            brakeKey[0] = Key.S;
            leftKey[0] = Key.A;
            rightKey[0] = Key.D;
        }


        private static void InitializePlayer2()
        {
            accelerateKey[1] = Key.UpArrow;
            brakeKey[1] = Key.DownArrow;
            leftKey[1] = Key.LeftArrow;
            rightKey[1] = Key.RightArrow;
        }
    }
}
